<!DOCTYPE html>
<html>
<head><meta name="generator" content="Hexo 3.8.0">
  <meta charset="utf-8">
  
  <title>Vue富文本编辑器 | </title>
  <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
  
    <meta name="keywords" content="EricWang's Blog">
  
  <meta name="description" content="Vue&amp;#x5BCC;&amp;#x6587;&amp;#x672C;&amp;#x7F16;&amp;#x8F91;&amp;#x5668;&amp;#x4ECB;&amp;#x7ECD; &amp;#x5728;&amp;#x505A;&amp;#x9879;&amp;#x76EE;&amp;#x4E2D;&amp;#x5076;&amp;#x7136;&amp;#x9047;&amp;#x89C1;&amp;#x4E86;&amp;#x4F7F;&amp;#x7528;&amp;#x5BCC;&amp;#x6587;&amp;#x672C;&amp;#x7F16;&amp;#x8">
<meta name="keywords" content="Vue,富文本编辑器">
<meta property="og:type" content="article">
<meta property="og:title" content="Vue富文本编辑器">
<meta property="og:url" content="https://bigbigdreamer.github.io/9f10.html">
<meta property="og:site_name">
<meta property="og:description" content="Vue&amp;#x5BCC;&amp;#x6587;&amp;#x672C;&amp;#x7F16;&amp;#x8F91;&amp;#x5668;&amp;#x4ECB;&amp;#x7ECD; &amp;#x5728;&amp;#x505A;&amp;#x9879;&amp;#x76EE;&amp;#x4E2D;&amp;#x5076;&amp;#x7136;&amp;#x9047;&amp;#x89C1;&amp;#x4E86;&amp;#x4F7F;&amp;#x7528;&amp;#x5BCC;&amp;#x6587;&amp;#x672C;&amp;#x7F16;&amp;#x8">
<meta property="og:locale" content="default">
<meta property="og:updated_time" content="2018-12-30T00:54:50.540Z">
<meta name="twitter:card" content="summary">
<meta name="twitter:title" content="Vue富文本编辑器">
<meta name="twitter:description" content="Vue&amp;#x5BCC;&amp;#x6587;&amp;#x672C;&amp;#x7F16;&amp;#x8F91;&amp;#x5668;&amp;#x4ECB;&amp;#x7ECD; &amp;#x5728;&amp;#x505A;&amp;#x9879;&amp;#x76EE;&amp;#x4E2D;&amp;#x5076;&amp;#x7136;&amp;#x9047;&amp;#x89C1;&amp;#x4E86;&amp;#x4F7F;&amp;#x7528;&amp;#x5BCC;&amp;#x6587;&amp;#x672C;&amp;#x7F16;&amp;#x8">
  
  
    <link rel="icon" href="favicon.ico">
  
  <link href="//cdn.bootcss.com/font-awesome/4.7.0/css/font-awesome.min.css" rel="stylesheet" type="text/css">
  <link rel="stylesheet" href="/css/style.css">
  <script src="/js/pace.min.js"></script>
  

  
	<script>
	var _hmt = _hmt || [];
	(function() {
	  var hm = document.createElement("script");
	  hm.src = "//hm.baidu.com/hm.js?490c72c80e7c5f485272ffc6d84c956b";
	  var s = document.getElementsByTagName("script")[0]; 
	  s.parentNode.insertBefore(hm, s);
	})();
	</script>

  

  <script>
    (function(){
      var bp = document.createElement('script');
      var curProtocol = window.location.protocol.split(':')[0];
      if (curProtocol === 'https') {
        bp.src = 'https://zz.bdstatic.com/linksubmit/push.js';
      }
      else {
        bp.src = 'http://push.zhanzhang.baidu.com/push.js';
      }
      var s = document.getElementsByTagName("script")[0];
      s.parentNode.insertBefore(bp, s);
    })();
  </script>
  <meta name="google-site-verification" content="2yIvO7JmvHMSNv3topeJQ8rrtv6HN-mKjYLR5sdxeaQ">
</head>
</html>
<body>
  <div id="container">
      <header id="header">
    <div id="banner"></div>
    <div id="header-outer">
        <div id="header-menu" class="header-menu-pos animated">
            <div class="header-menu-container">
                <a href="/" class="left">
                    <span class="site-title">BigDreamer</span>
                </a>
                <nav id="header-menu-nav" class="right">
                    
                    <a href="/">
                        <i class="fa fa-home"></i>
                        <span>Home</span>
                    </a>
                    
                    <a href="/archives">
                        <i class="fa fa-archive"></i>
                        <span>Archives</span>
                    </a>
                    
                    <a href="/about">
                        <i class="fa fa-user"></i>
                        <span>About</span>
                    </a>
                    
                </nav>
                <a class="mobile-header-menu-button">
                    <i class="fa fa-bars"></i>
                </a>
            </div>
        </div>
        <div id="header-row">
            <div id="logo">
                <a href="/">
                    <img src="/images/logo.jpg" alt="logo">
                </a>
            </div>
            <div class="header-info">
                <div id="header-title">
                    
                    <h2>
                        BigDreamer
                    </h2>
                    
                </div>
                <div id="header-description">
                    
                    <h3>
                        情不知所起，一往而深。
                    </h3>
                    
                </div>
            </div>
            <nav class="header-nav">
                <div class="social">
                    
                        <a title="EricWang" target="_blank" href="//ivu1314.club">
                            <i class="fa fa-home fa-2x"></i></a>
                    
                        <a title="Github" target="_blank" href="https://github.com/bigbigDreamer">
                            <i class="fa fa-github fa-2x"></i></a>
                    
                        <a title="QQ" target="_blank" href="http://wpa.qq.com/msgrd?v=3&uin=1826001146&site=qq&menu=yes">
                            <i class="fa fa-qq fa-2x"></i></a>
                    
                </div>
            </nav>
        </div>
    </div>
</header>
      <div class="outer">
        <section id="main" class="body-wrap"><article id="post-Vue富文本编辑器" class="article article-type-post" itemscope="" itemprop="blogPost">
  <div class="article-inner">
    
      <header class="article-header">
        
  
    <h1 class="post-title" itemprop="name">
      Vue富文本编辑器
    </h1>
    <div class="post-title-bar">
      <ul>
          
              <li>
                  <i class="fa fa-book"></i>
                  
                      <a href="/categories/经验/">经验</a>
                  
              </li>
          
        <li>
          <i class="fa fa-calendar"></i>  2018-12-20
        </li>
        <li>
          <i class="fa fa-eye"></i>
          <span id="busuanzi_value_page_pv"></span>
        </li>
      </ul>
    </div>
  

          
      </header>
    
    <div class="article-entry post-content" itemprop="articleBody">
      
            
            <h2 id="Vue&#x5BCC;&#x6587;&#x672C;&#x7F16;&#x8F91;&#x5668;"><a href="#Vue&#x5BCC;&#x6587;&#x672C;&#x7F16;&#x8F91;&#x5668;" class="headerlink" title="Vue&#x5BCC;&#x6587;&#x672C;&#x7F16;&#x8F91;&#x5668;"></a>Vue&#x5BCC;&#x6587;&#x672C;&#x7F16;&#x8F91;&#x5668;</h2><h3 id="&#x4ECB;&#x7ECD;"><a href="#&#x4ECB;&#x7ECD;" class="headerlink" title="&#x4ECB;&#x7ECD;"></a>&#x4ECB;&#x7ECD;</h3><blockquote>
<p>&#x5728;&#x505A;&#x9879;&#x76EE;&#x4E2D;&#x5076;&#x7136;&#x9047;&#x89C1;&#x4E86;&#x4F7F;&#x7528;&#x5BCC;&#x6587;&#x672C;&#x7F16;&#x8F91;&#x5668;&#x7684;&#x4EFB;&#x52A1;&#xFF0C;&#x6240;&#x4EE5;&#x4FBF;&#x7814;&#x7A76;&#x4E86;&#x4E00;&#x756A;&#xFF0C;&#x518D;&#x6B21;&#x603B;&#x7ED3;&#x5185;&#x529F;&#x5FC3;&#x6CD5;&#xFF0C;&#x4EE5;&#x4FBF;&#x5728;&#x4E0B;&#x6B21;&#x4F7F;&#x7528;&#x4E2D;&#x987A;&#x5229;&#x524D;&#x884C;&#x3002;</p>
</blockquote>
<h3 id="vue-quill-editor"><a href="#vue-quill-editor" class="headerlink" title="vue-quill-editor"></a><a href="https://github.com/surmon-china/vue-quill-editor" target="_blank" rel="noopener">vue-quill-editor</a></h3><blockquote>
<p>&#x4E00;&#x6B3E;&#x5F3A;&#x5927;&#x7684;&#x5BCC;&#x6587;&#x672C;&#x7F16;&#x8F91;&#x5668;&#xFF0C;&#x53EF;&#x4EE5;&#x5185;&#x5D4C;&#x5165;vue&#xFF0C;&#x5E76;&#x4E14;&#x652F;&#x6301;&#x591A;&#x4E8B;&#x4EF6;&#x56DE;&#x8C03;&#x3002;</p>
</blockquote>
<h3 id="&#x89E3;&#x51B3;&#x56FE;&#x7247;&#x4E0A;&#x4F20;"><a href="#&#x89E3;&#x51B3;&#x56FE;&#x7247;&#x4E0A;&#x4F20;" class="headerlink" title="&#x89E3;&#x51B3;&#x56FE;&#x7247;&#x4E0A;&#x4F20;"></a>&#x89E3;&#x51B3;&#x56FE;&#x7247;&#x4E0A;&#x4F20;</h3><blockquote>
<p>&#x4F9D;&#x8D56;&#x4E8E;&#x4E00;&#x4E2A;&#x63D2;&#x4EF6;<a href="https://github.com/NextBoy/quill-image-extend-module" target="_blank" rel="noopener">quill-image-extend-module</a></p>
</blockquote>
<blockquote>
<p>&#x539F;&#x7406;&#xFF0C;&#x62C6;&#x5206;&#x539F;&#x751F;&#x5BCC;&#x6587;&#x672C;&#x7F16;&#x8F91;&#x5668;&#x7684;&#x56FE;&#x7247;&#x4E0A;&#x4F20;&#x3002;</p>
</blockquote>
<blockquote>
<p>&#x4EE3;&#x7801;&#x5B9E;&#x4F8B;</p>
</blockquote>
<figure class="highlight plain"><table><tbody><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br><span class="line">8</span><br><span class="line">9</span><br><span class="line">10</span><br><span class="line">11</span><br><span class="line">12</span><br><span class="line">13</span><br><span class="line">14</span><br><span class="line">15</span><br><span class="line">16</span><br><span class="line">17</span><br><span class="line">18</span><br><span class="line">19</span><br><span class="line">20</span><br><span class="line">21</span><br><span class="line">22</span><br><span class="line">23</span><br><span class="line">24</span><br><span class="line">25</span><br><span class="line">26</span><br><span class="line">27</span><br><span class="line">28</span><br><span class="line">29</span><br><span class="line">30</span><br><span class="line">31</span><br><span class="line">32</span><br><span class="line">33</span><br><span class="line">34</span><br><span class="line">35</span><br><span class="line">36</span><br><span class="line">37</span><br><span class="line">38</span><br><span class="line">39</span><br><span class="line">40</span><br><span class="line">41</span><br><span class="line">42</span><br><span class="line">43</span><br><span class="line">44</span><br><span class="line">45</span><br><span class="line">46</span><br><span class="line">47</span><br><span class="line">48</span><br><span class="line">49</span><br><span class="line">50</span><br><span class="line">51</span><br><span class="line">52</span><br><span class="line">53</span><br><span class="line">54</span><br><span class="line">55</span><br><span class="line">56</span><br><span class="line">57</span><br><span class="line">58</span><br><span class="line">59</span><br><span class="line">60</span><br><span class="line">61</span><br><span class="line">62</span><br><span class="line">63</span><br><span class="line">64</span><br><span class="line">65</span><br><span class="line">66</span><br><span class="line">67</span><br><span class="line">68</span><br><span class="line">69</span><br><span class="line">70</span><br><span class="line">71</span><br><span class="line">72</span><br><span class="line">73</span><br><span class="line">74</span><br><span class="line">75</span><br><span class="line">76</span><br><span class="line">77</span><br><span class="line">78</span><br><span class="line">79</span><br><span class="line">80</span><br><span class="line">81</span><br><span class="line">82</span><br><span class="line">83</span><br><span class="line">84</span><br><span class="line">85</span><br><span class="line">86</span><br><span class="line">87</span><br><span class="line">88</span><br><span class="line">89</span><br><span class="line">90</span><br><span class="line">91</span><br><span class="line">92</span><br><span class="line">93</span><br><span class="line">94</span><br><span class="line">95</span><br><span class="line">96</span><br><span class="line">97</span><br><span class="line">98</span><br><span class="line">99</span><br><span class="line">100</span><br><span class="line">101</span><br><span class="line">102</span><br><span class="line">103</span><br><span class="line">104</span><br><span class="line">105</span><br><span class="line">106</span><br><span class="line">107</span><br><span class="line">108</span><br><span class="line">109</span><br><span class="line">110</span><br><span class="line">111</span><br><span class="line">112</span><br><span class="line">113</span><br><span class="line">114</span><br><span class="line">115</span><br><span class="line">116</span><br><span class="line">117</span><br><span class="line">118</span><br><span class="line">119</span><br><span class="line">120</span><br><span class="line">121</span><br></pre></td><td class="code"><pre><span class="line">&lt;template&gt;</span><br><span class="line">    &lt;Row&gt;</span><br><span class="line">        &lt;Col span=&quot;24&quot; class=&quot;publishBtn&quot;&gt;</span><br><span class="line">            &lt;Button :size=&quot;buttonSize&quot; icon=&quot;ios-cloud-upload-outline&quot; class=&quot;btn&quot; @click=&quot;publicNews&quot;&gt;&#x53D1;&#x5E03;&lt;/Button&gt;</span><br><span class="line">        &lt;/Col&gt;</span><br><span class="line">        &lt;Col span=&quot;24&quot;&gt;</span><br><span class="line">            &lt;Input v-model=&quot;title&quot; type=&quot;textarea&quot; placeholder=&quot;&#x8BF7;&#x8F93;&#x5165;&#x6587;&#x7AE0;&#x6807;&#x9898;&quot; class=&quot;title&quot;/&gt;</span><br><span class="line">        &lt;/Col&gt;</span><br><span class="line">        &lt;br&gt;</span><br><span class="line">        &lt;Col span=&quot;24&quot;&gt;</span><br><span class="line">            &lt;quill-editor v-model=&quot;content&quot;</span><br><span class="line">                          ref=&quot;myQuillEditor&quot;</span><br><span class="line">                          :options=&quot;editorOption&quot;</span><br><span class="line">                          @change=&quot;onEditorChange($event)&quot;</span><br><span class="line">                          @blur=&quot;onEditorBlur($event)&quot;</span><br><span class="line">                          @focus=&quot;onEditorFocus($event)&quot;</span><br><span class="line">                          @ready=&quot;onEditorReady($event)&quot;</span><br><span class="line">                          class=&quot;editor&quot;&gt;</span><br><span class="line">            &lt;/quill-editor&gt;</span><br><span class="line">        &lt;/Col&gt;</span><br><span class="line">    &lt;/Row&gt;</span><br><span class="line">&lt;/template&gt;</span><br><span class="line"></span><br><span class="line">&lt;script&gt;</span><br><span class="line">    import {quillEditor, Quill} from &apos;vue-quill-editor&apos;</span><br><span class="line">    import {container, ImageExtend, QuillWatch} from &apos;quill-image-extend-module&apos;</span><br><span class="line"></span><br><span class="line">    Quill.register(&apos;modules/ImageExtend&apos;, ImageExtend)</span><br><span class="line">    export default {</span><br><span class="line">        name: &quot;newsPublish&quot;,</span><br><span class="line">        data() {</span><br><span class="line">            return {</span><br><span class="line">                //&#x6309;&#x94AE;&#x5927;&#x5C0F;</span><br><span class="line">                buttonSize: &apos;large&apos;,</span><br><span class="line">                //&#x65B0;&#x95FB;&#x5185;&#x5BB9;</span><br><span class="line">                content: &apos;&lt;h2&gt;&#x8BF7;&#x8F93;&#x5165;&#x4F60;&#x7684;&#x5185;&#x5BB9;......&lt;/h2&gt;&apos;,</span><br><span class="line">                //&#x56FE;&#x7247;&#x76F8;&#x5BF9;&#x5730;&#x5740;</span><br><span class="line">                pic: &apos;&apos;,</span><br><span class="line">                //&#x6587;&#x7AE0;&#x6807;&#x9898;</span><br><span class="line">                title: &apos;&apos;,</span><br><span class="line">                //&#x53D1;&#x5E03;&#x4EBA;</span><br><span class="line">                publisher: &apos;&apos;,</span><br><span class="line">                //&#x5BCC;&#x6587;&#x672C;&#x7F16;&#x8F91;&#x5668;&#x76F8;&#x5173;&#x914D;&#x7F6E;</span><br><span class="line">                editorOption: {</span><br><span class="line">                    // some quill options</span><br><span class="line">                    modules: {</span><br><span class="line">                        ImageExtend: {</span><br><span class="line">                            loading: true,</span><br><span class="line">                            name: &apos;myFile&apos;,</span><br><span class="line">                            action: &apos;/file/uploadPic&apos;,</span><br><span class="line">                            response: (res) =&gt; {</span><br><span class="line">                                console.log(res);</span><br><span class="line">                                this.pic = res.message;</span><br><span class="line">                                return `url`;</span><br><span class="line">                            },</span><br><span class="line">                            change: (xhr, formData) =&gt; {</span><br><span class="line">                                // xhr.setRequestHeader(&apos;myHeader&apos;,&apos;myValue&apos;)</span><br><span class="line">                                // formData.append(&apos;token&apos;, &apos;myToken&apos;)</span><br><span class="line">                            } // &#x53EF;&#x9009;&#x53C2;</span><br><span class="line">                        },</span><br><span class="line">                        toolbar: {</span><br><span class="line">                            container: container,</span><br><span class="line">                            handlers: {</span><br><span class="line">                                &apos;image&apos;: function () {</span><br><span class="line">                                    QuillWatch.emit(this.quill.id)</span><br><span class="line">                                }</span><br><span class="line">                            }</span><br><span class="line">                        }</span><br><span class="line">                    }</span><br><span class="line">                }</span><br><span class="line">            }</span><br><span class="line">        },</span><br><span class="line">        methods: {</span><br><span class="line">            //&#x5BCC;&#x6587;&#x672C;&#x7F16;&#x8F91;&#x5668;&#x5931;&#x53BB;&#x7126;&#x70B9;</span><br><span class="line">            onEditorBlur(quill) {</span><br><span class="line">                //console.log(&apos;editor blur!&apos;, quill)</span><br><span class="line">            },</span><br><span class="line">            //&#x5BCC;&#x6587;&#x672C;&#x7F16;&#x8F91;&#x5668;&#x83B7;&#x53D6;&#x7126;&#x70B9;</span><br><span class="line">            onEditorFocus(quill) {</span><br><span class="line">                // console.log(&apos;editor focus!&apos;, quill)</span><br><span class="line">            },</span><br><span class="line">            //&#x5BCC;&#x6587;&#x672C;&#x7F16;&#x8F91;&#x5668;&#x5DF2;&#x7ECF;&#x505A;&#x597D;&#x51C6;&#x5907;</span><br><span class="line">            onEditorReady(quill) {</span><br><span class="line">                //console.log(&apos;editor ready!&apos;, quill)</span><br><span class="line">            },</span><br><span class="line">            //&#x5F53;&#x5BCC;&#x6587;&#x672C;&#x7F16;&#x8F91;&#x5668;&#x5185;&#x5BB9;&#x6539;&#x53D8;&#x7684;&#x65F6;&#x5019;&#xFF0C;&#x83B7;&#x53D6;html&#x5BCC;&#x6587;&#x672C;</span><br><span class="line">            onEditorChange({quill, html, text}) {</span><br><span class="line">                console.log(html);</span><br><span class="line">                this.content = html</span><br><span class="line">            },</span><br><span class="line">            /**</span><br><span class="line">             * @time  2018/12/19 20:04</span><br><span class="line">             * @author  Bill Wang &lt;vuejs@vip.qq.com&gt;</span><br><span class="line">             * @desc  &#x53D1;&#x5E03;&#x56FE;&#x7247;</span><br><span class="line">             */</span><br><span class="line">            publicNews() {</span><br><span class="line">                this.$ajax.post(&apos;/news/saveNews&apos;, {</span><br><span class="line">                    publisher: &apos;&#x6682;&#x4E0D;&#x5904;&#x7406;&apos;,</span><br><span class="line">                    title: `&lt;h1&gt;${this.title}&lt;/h1&gt;`,</span><br><span class="line">                    content: this.content,</span><br><span class="line">                    pic: this.pic,</span><br><span class="line">                })</span><br><span class="line">                    .then((data) =&gt; {</span><br><span class="line">                        console.log(data);</span><br><span class="line">                    })</span><br><span class="line">                    .catch((err) =&gt; {</span><br><span class="line">                        console.log(err);</span><br><span class="line">                    })</span><br><span class="line">            }</span><br><span class="line">        },</span><br><span class="line">        computed: {</span><br><span class="line">            editor() {</span><br><span class="line">                return this.$refs.myQuillEditor.quill</span><br><span class="line">            }</span><br><span class="line">        },</span><br><span class="line">        mounted() {</span><br><span class="line">            //&#x6B64;&#x5904;&#x9700;&#x8981;&#x89E3;&#x51B3;&#x7684;&#x4E00;&#x4E2A;&#x95EE;&#x9898;&#x5C31;&#x662F;&#x5BF9;&#x4E8E;&#x8FD9;&#x4E2A;&#x5BCC;&#x6587;&#x672C;&#x7F16;&#x8F91;&#x5668;&#x7684;&#x56FE;&#x7247;&#x4E0A;&#x4F20;&#x4F5C;&#x4F55;&#x5904;&#x7406;</span><br><span class="line">            //console.log(&apos;this is current quill instance object&apos;, this.editor)</span><br><span class="line">        }</span><br><span class="line">    }</span><br><span class="line">&lt;/script&gt;</span><br></pre></td></tr></tbody></table></figure>
<script>
        document.querySelectorAll('.github-emoji')
          .forEach(el => {
            if (!el.dataset.src) { return; }
            const img = document.createElement('img');
            img.style = 'display:none !important;';
            img.src = el.dataset.src;
            img.addEventListener('error', () => {
              img.remove();
              el.style.color = 'inherit';
              el.style.backgroundImage = 'none';
              el.style.background = 'none';
            });
            img.addEventListener('load', () => {
              img.remove();
            });
            document.body.appendChild(img);
          });
      </script>
            <div class="post-copyright">
    <div class="content">
        <p>最后更新： 2018年12月30日 08:54</p>
        <p>原始链接： <a class="post-url" href="/9f10.html" title="Vue富文本编辑器">https://bigbigdreamer.github.io/9f10.html</a></p>
        <footer>
            <a href="https://bigbigdreamer.github.io">
                <img src="/images/logo.jpg" alt="">
                
            </a>
        </footer>
    </div>
</div>

      
        
            
<div class="page-reward">
    <a id="rewardBtn" href="javascript:;">赏</a>
</div>

<div id="reward" class="post-modal reward-lay">
    <a class="close" href="javascript:;" id="reward-close">×</a>
    <span class="reward-title">
        <i class="icon icon-quote-left"></i>
        请我吃糖~
        <i class="icon icon-quote-right"></i>
    </span>
    <div class="reward-content">
        
        <div class="reward-code">
            <img id="rewardCode" src="/images/wechat_code.jpg" alt="打赏二维码">
        </div>
        <div class="reward-select">
            
            <label class="reward-select-item checked" data-id="wechat" data-wechat="/images/wechat_code.jpg">
                <img class="reward-select-item-wechat" src="/images/wechat.png" alt="微信">
            </label>
            
            
            <label class="reward-select-item" data-id="alipay" data-alipay="/images/alipay_code.jpg">
                <img class="reward-select-item-alipay" src="/images/alipay.png" alt="支付宝">
            </label>
            
        </div>
    </div>
</div>


        
    </div>
    <footer class="article-footer">
        
        
<div class="post-share">
    <a href="javascript:;" id="share-sub" class="post-share-fab">
        <i class="fa fa-share-alt"></i>
    </a>
    <div class="post-share-list" id="share-list">
        <ul class="share-icons">
          <li>
            <a class="weibo share-sns" target="_blank" href="http://service.weibo.com/share/share.php?url=https://bigbigdreamer.github.io/9f10.html&title=《Vue富文本编辑器》 — null&pic=https://bigbigdreamer.github.ioimages/logo.jpg" data-title="微博">
              <i class="fa fa-weibo"></i>
            </a>
          </li>
          <li>
            <a class="weixin share-sns" id="wxFab" href="javascript:;" data-title="微信">
              <i class="fa fa-weixin"></i>
            </a>
          </li>
          <li>
            <a class="qq share-sns" target="_blank" href="http://connect.qq.com/widget/shareqq/index.html?url=https://bigbigdreamer.github.io/9f10.html&title=《Vue富文本编辑器》 — null&source=" data-title="QQ">
              <i class="fa fa-qq"></i>
            </a>
          </li>
          <li>
            <a class="facebook share-sns" target="_blank" href="https://www.facebook.com/sharer/sharer.php?u=https://bigbigdreamer.github.io/9f10.html" data-title="Facebook">
              <i class="fa fa-facebook"></i>
            </a>
          </li>
          <li>
            <a class="twitter share-sns" target="_blank" href="https://twitter.com/intent/tweet?text=《Vue富文本编辑器》 — null&url=https://bigbigdreamer.github.io/9f10.html&via=https://bigbigdreamer.github.io" data-title="Twitter">
              <i class="fa fa-twitter"></i>
            </a>
          </li>
          <li>
            <a class="google share-sns" target="_blank" href="https://plus.google.com/share?url=https://bigbigdreamer.github.io/9f10.html" data-title="Google+">
              <i class="fa fa-google-plus"></i>
            </a>
          </li>
        </ul>
     </div>
</div>
<div class="post-modal wx-share" id="wxShare">
    <a class="close" href="javascript:;" id="wxShare-close">×</a>
    <p>扫一扫，分享到微信</p>
    <img src="//api.qrserver.com/v1/create-qr-code/?data=https://bigbigdreamer.github.io/9f10.html" alt="微信分享二维码">
</div>

<div class="mask"></div>

        
        <ul class="article-footer-menu">
            
            
  <li class="article-footer-tags">
    <i class="fa fa-tags"></i>
      
    <a href="/tags/Vue/" class="color4">Vue</a>
      
    <a href="/tags/富文本编辑器/" class="color2">富文本编辑器</a>
      
  </li>

        </ul>
        
    </footer>
  </div>
</article>


    <aside class="post-toc-pos post-toc-top" id="post-toc">
        <nav class="post-toc-wrap">
            <ol class="post-toc"><li class="post-toc-item post-toc-level-2"><a class="post-toc-link" href="#Vue富文本编辑器"><span class="post-toc-text">Vue富文本编辑器</span></a><ol class="post-toc-child"><li class="post-toc-item post-toc-level-3"><a class="post-toc-link" href="#介绍"><span class="post-toc-text">介绍</span></a></li><li class="post-toc-item post-toc-level-3"><a class="post-toc-link" href="#vue-quill-editor"><span class="post-toc-text">vue-quill-editor</span></a></li><li class="post-toc-item post-toc-level-3"><a class="post-toc-link" href="#解决图片上传"><span class="post-toc-text">解决图片上传</span></a></li></ol></li></ol>
        </nav>
    </aside>
    

<nav id="article-nav">
  
    <a href="/73df.html" id="article-nav-newer" class="article-nav-link-wrap">

      <span class="article-nav-title">
        <i class="fa fa-hand-o-left" aria-hidden="true"></i>
        
          iview表格事宜
        
      </span>
    </a>
  
  
    <a href="/9c29.html" id="article-nav-older" class="article-nav-link-wrap">
      <span class="article-nav-title">从零搭建个人博客</span>
      <i class="fa fa-hand-o-right" aria-hidden="true"></i>
    </a>
  
</nav>



    
        <div id="SOHUCS" sid="Vue富文本编辑器"></div>
<script type="text/javascript">
    (function(){
        var appid = 'cytVQxp6s';
        var conf = 'prod_8686c5c96a3bc67353ba410e4bcb37a9';
        var width = window.innerWidth || document.documentElement.clientWidth;
        if (width < 960) {
            window.document.write('<script id="changyan_mobile_js" charset="utf-8" type="text/javascript" src="https://changyan.sohu.com/upload/mobile/wap-js/changyan_mobile.js?client_id=' + appid + '&conf=' + conf + '"><\/script>'); } else { var loadJs=function(d,a){var c=document.getElementsByTagName("head")[0]||document.head||document.documentElement;var b=document.createElement("script");b.setAttribute("type","text/javascript");b.setAttribute("charset","UTF-8");b.setAttribute("src",d);if(typeof a==="function"){if(window.attachEvent){b.onreadystatechange=function(){var e=b.readyState;if(e==="loaded"||e==="complete"){b.onreadystatechange=null;a()}}}else{b.onload=a}}c.appendChild(b)};loadJs("https://changyan.sohu.com/upload/changyan.js",function(){window.changyan.api.config({appid:appid,conf:conf})}); } })(); </script>
    
</section>
        
      </div>
      <footer id="footer">
  <div class="outer">
    <div id="footer-info" class="inner">
      
<p>
    <span id="busuanzi_container_site_uv" style="display:none">
        总访客数：<span id="busuanzi_value_site_uv"></span>
    </span>
    <span id="busuanzi_container_site_pv" style="display:none">
        总访问量：<span id="busuanzi_value_site_pv"></span>
    </span>
</p>


      <p>
        Powered by  <a href="http://hexo.io/" target="_blank">Hexo</a>
        Theme <a href="//github.com/wongminho/hexo-theme-miho" target="_blank">MiHo</a>
      &copy; 2019 <br>
      </p>
    </div>
  </div>
</footer>
    <script async src="//busuanzi.ibruce.info/busuanzi/2.3/busuanzi.pure.mini.js"></script>
<script src="//cdn.bootcss.com/jquery/3.2.1/jquery.min.js"></script>
<script>
  var mihoConfig = {
      root: "https://bigbigdreamer.github.io",
      animate: true,
      isHome: false,
      share: true,
      reward: 1
  }
</script>
<div class="sidebar">
    <div id="sidebar-search" title="Search">
        <i class="fa fa-search"></i>
    </div>
    <div id="sidebar-category" title="Categories">
        <i class="fa fa-book"></i>
    </div>
    <div id="sidebar-tag" title="Tags">
        <i class="fa fa-tags"></i>
    </div>
    <div id="sidebar-top">
        <span class="sidebar-top-icon"><i class="fa fa-angle-up"></i></span>
    </div>
</div>
<div class="sidebar-menu-box" id="sidebar-menu-box">
    <div class="sidebar-menu-box-container">
        <div id="sidebar-menu-box-categories">
            <a class="category-link" href="/categories/CSS/">CSS</a><a class="category-link" href="/categories/ES6/">ES6</a><a class="category-link" href="/categories/Linux/">Linux</a><a class="category-link" href="/categories/Node/">Node</a><a class="category-link" href="/categories/Vue/">Vue</a><a class="category-link" href="/categories/Vue-Router/">Vue-Router</a><a class="category-link" href="/categories/ajax/">ajax</a><a class="category-link" href="/categories/前端接口调试/">前端接口调试</a><a class="category-link" href="/categories/杂货/">杂货</a><a class="category-link" href="/categories/经验/">经验</a><a class="category-link" href="/categories/设计模式/">设计模式</a>
        </div>
        <div id="sidebar-menu-box-tags">
            <a href="/tags/Async/" style="font-size: 10px;">Async</a> <a href="/tags/Babel-7-0/" style="font-size: 10px;">Babel 7.0</a> <a href="/tags/CSS/" style="font-size: 10px;">CSS</a> <a href="/tags/CSS3/" style="font-size: 10px;">CSS3</a> <a href="/tags/CSS样式/" style="font-size: 10px;">CSS样式</a> <a href="/tags/Collapse/" style="font-size: 10px;">Collapse</a> <a href="/tags/DMZ/" style="font-size: 10px;">DMZ</a> <a href="/tags/DOM/" style="font-size: 10px;">DOM</a> <a href="/tags/ES6/" style="font-size: 17.5px;">ES6</a> <a href="/tags/EXT/" style="font-size: 10px;">EXT</a> <a href="/tags/FAT/" style="font-size: 10px;">FAT</a> <a href="/tags/Function/" style="font-size: 10px;">Function</a> <a href="/tags/HTML5/" style="font-size: 10px;">HTML5</a> <a href="/tags/Hexo/" style="font-size: 10px;">Hexo</a> <a href="/tags/JS/" style="font-size: 10px;">JS</a> <a href="/tags/JS模块化/" style="font-size: 10px;">JS模块化</a> <a href="/tags/JavaScript/" style="font-size: 10px;">JavaScript</a> <a href="/tags/Less/" style="font-size: 10px;">Less</a> <a href="/tags/Linux/" style="font-size: 10px;">Linux</a> <a href="/tags/MarkDown/" style="font-size: 10px;">MarkDown</a> <a href="/tags/Modal/" style="font-size: 10px;">Modal</a> <a href="/tags/Node/" style="font-size: 10px;">Node</a> <a href="/tags/Promise/" style="font-size: 12.5px;">Promise</a> <a href="/tags/Render/" style="font-size: 10px;">Render</a> <a href="/tags/Sync/" style="font-size: 10px;">Sync</a> <a href="/tags/Template/" style="font-size: 10px;">Template</a> <a href="/tags/Vue/" style="font-size: 20px;">Vue</a> <a href="/tags/WebStorm/" style="font-size: 10px;">WebStorm</a> <a href="/tags/ajax/" style="font-size: 10px;">ajax</a> <a href="/tags/axios/" style="font-size: 10px;">axios</a> <a href="/tags/bat文件/" style="font-size: 10px;">bat文件</a> <a href="/tags/dos/" style="font-size: 10px;">dos</a> <a href="/tags/es6/" style="font-size: 10px;">es6</a> <a href="/tags/exports/" style="font-size: 10px;">exports</a> <a href="/tags/git/" style="font-size: 10px;">git</a> <a href="/tags/github/" style="font-size: 10px;">github</a> <a href="/tags/iview/" style="font-size: 15px;">iview</a> <a href="/tags/module-exports/" style="font-size: 10px;">module.exports</a> <a href="/tags/newTarget/" style="font-size: 10px;">newTarget</a> <a href="/tags/newYear/" style="font-size: 10px;">newYear</a> <a href="/tags/nginx/" style="font-size: 10px;">nginx</a> <a href="/tags/node/" style="font-size: 10px;">node</a> <a href="/tags/postman/" style="font-size: 10px;">postman</a> <a href="/tags/queue/" style="font-size: 10px;">queue</a> <a href="/tags/scope/" style="font-size: 10px;">scope</a> <a href="/tags/scroll/" style="font-size: 10px;">scroll</a> <a href="/tags/vue/" style="font-size: 15px;">vue</a> <a href="/tags/vue-cli3-0/" style="font-size: 10px;">vue @cli3.0</a> <a href="/tags/vue-cli3-0/" style="font-size: 10px;">vue-cli3.0</a> <a href="/tags/vue-router/" style="font-size: 10px;">vue-router</a> <a href="/tags/webpack/" style="font-size: 10px;">webpack</a> <a href="/tags/一曲相思/" style="font-size: 10px;">一曲相思</a> <a href="/tags/优化体验/" style="font-size: 10px;">优化体验</a> <a href="/tags/单例模式/" style="font-size: 10px;">单例模式</a> <a href="/tags/双大括号表达式/" style="font-size: 10px;">双大括号表达式</a> <a href="/tags/域名/" style="font-size: 10px;">域名</a> <a href="/tags/富文本编辑器/" style="font-size: 10px;">富文本编辑器</a> <a href="/tags/封装/" style="font-size: 10px;">封装</a> <a href="/tags/开发环境/" style="font-size: 10px;">开发环境</a> <a href="/tags/心情/" style="font-size: 10px;">心情</a> <a href="/tags/心灵驿站/" style="font-size: 10px;">心灵驿站</a> <a href="/tags/情感/" style="font-size: 10px;">情感</a> <a href="/tags/搜狐畅言/" style="font-size: 10px;">搜狐畅言</a> <a href="/tags/数据结构/" style="font-size: 10px;">数据结构</a> <a href="/tags/日常修仙/" style="font-size: 10px;">日常修仙</a> <a href="/tags/服务器数据Mock/" style="font-size: 10px;">服务器数据Mock</a> <a href="/tags/杂货/" style="font-size: 10px;">杂货</a> <a href="/tags/柯里化/" style="font-size: 10px;">柯里化</a> <a href="/tags/气泡提示/" style="font-size: 10px;">气泡提示</a> <a href="/tags/生产环境/" style="font-size: 10px;">生产环境</a> <a href="/tags/简单工厂模式/" style="font-size: 10px;">简单工厂模式</a> <a href="/tags/腾讯云/" style="font-size: 10px;">腾讯云</a> <a href="/tags/设计模式/" style="font-size: 12.5px;">设计模式</a> <a href="/tags/调试/" style="font-size: 10px;">调试</a> <a href="/tags/跨域/" style="font-size: 10px;">跨域</a>
        </div>
    </div>
    <a href="javascript:;" class="sidebar-menu-box-close">&times;</a>
</div>
<div class="mobile-header-menu-nav" id="mobile-header-menu-nav">
    <div class="mobile-header-menu-container">
        <span class="title">Menus</span>
        <ul class="mobile-header-menu-navbar">
            
            <li>
                <a href="/">
                    <i class="fa fa-home"></i><span>Home</span>
                </a>
            </li>
            
            <li>
                <a href="/archives">
                    <i class="fa fa-archive"></i><span>Archives</span>
                </a>
            </li>
            
            <li>
                <a href="/about">
                    <i class="fa fa-user"></i><span>About</span>
                </a>
            </li>
            
        </ul>
    </div>
    <div class="mobile-header-tag-container">
        <span class="title">Tags</span>
        <div id="mobile-header-container-tags">
            <a href="/tags/Async/" style="font-size: 10px;">Async</a> <a href="/tags/Babel-7-0/" style="font-size: 10px;">Babel 7.0</a> <a href="/tags/CSS/" style="font-size: 10px;">CSS</a> <a href="/tags/CSS3/" style="font-size: 10px;">CSS3</a> <a href="/tags/CSS样式/" style="font-size: 10px;">CSS样式</a> <a href="/tags/Collapse/" style="font-size: 10px;">Collapse</a> <a href="/tags/DMZ/" style="font-size: 10px;">DMZ</a> <a href="/tags/DOM/" style="font-size: 10px;">DOM</a> <a href="/tags/ES6/" style="font-size: 17.5px;">ES6</a> <a href="/tags/EXT/" style="font-size: 10px;">EXT</a> <a href="/tags/FAT/" style="font-size: 10px;">FAT</a> <a href="/tags/Function/" style="font-size: 10px;">Function</a> <a href="/tags/HTML5/" style="font-size: 10px;">HTML5</a> <a href="/tags/Hexo/" style="font-size: 10px;">Hexo</a> <a href="/tags/JS/" style="font-size: 10px;">JS</a> <a href="/tags/JS模块化/" style="font-size: 10px;">JS模块化</a> <a href="/tags/JavaScript/" style="font-size: 10px;">JavaScript</a> <a href="/tags/Less/" style="font-size: 10px;">Less</a> <a href="/tags/Linux/" style="font-size: 10px;">Linux</a> <a href="/tags/MarkDown/" style="font-size: 10px;">MarkDown</a> <a href="/tags/Modal/" style="font-size: 10px;">Modal</a> <a href="/tags/Node/" style="font-size: 10px;">Node</a> <a href="/tags/Promise/" style="font-size: 12.5px;">Promise</a> <a href="/tags/Render/" style="font-size: 10px;">Render</a> <a href="/tags/Sync/" style="font-size: 10px;">Sync</a> <a href="/tags/Template/" style="font-size: 10px;">Template</a> <a href="/tags/Vue/" style="font-size: 20px;">Vue</a> <a href="/tags/WebStorm/" style="font-size: 10px;">WebStorm</a> <a href="/tags/ajax/" style="font-size: 10px;">ajax</a> <a href="/tags/axios/" style="font-size: 10px;">axios</a> <a href="/tags/bat文件/" style="font-size: 10px;">bat文件</a> <a href="/tags/dos/" style="font-size: 10px;">dos</a> <a href="/tags/es6/" style="font-size: 10px;">es6</a> <a href="/tags/exports/" style="font-size: 10px;">exports</a> <a href="/tags/git/" style="font-size: 10px;">git</a> <a href="/tags/github/" style="font-size: 10px;">github</a> <a href="/tags/iview/" style="font-size: 15px;">iview</a> <a href="/tags/module-exports/" style="font-size: 10px;">module.exports</a> <a href="/tags/newTarget/" style="font-size: 10px;">newTarget</a> <a href="/tags/newYear/" style="font-size: 10px;">newYear</a> <a href="/tags/nginx/" style="font-size: 10px;">nginx</a> <a href="/tags/node/" style="font-size: 10px;">node</a> <a href="/tags/postman/" style="font-size: 10px;">postman</a> <a href="/tags/queue/" style="font-size: 10px;">queue</a> <a href="/tags/scope/" style="font-size: 10px;">scope</a> <a href="/tags/scroll/" style="font-size: 10px;">scroll</a> <a href="/tags/vue/" style="font-size: 15px;">vue</a> <a href="/tags/vue-cli3-0/" style="font-size: 10px;">vue @cli3.0</a> <a href="/tags/vue-cli3-0/" style="font-size: 10px;">vue-cli3.0</a> <a href="/tags/vue-router/" style="font-size: 10px;">vue-router</a> <a href="/tags/webpack/" style="font-size: 10px;">webpack</a> <a href="/tags/一曲相思/" style="font-size: 10px;">一曲相思</a> <a href="/tags/优化体验/" style="font-size: 10px;">优化体验</a> <a href="/tags/单例模式/" style="font-size: 10px;">单例模式</a> <a href="/tags/双大括号表达式/" style="font-size: 10px;">双大括号表达式</a> <a href="/tags/域名/" style="font-size: 10px;">域名</a> <a href="/tags/富文本编辑器/" style="font-size: 10px;">富文本编辑器</a> <a href="/tags/封装/" style="font-size: 10px;">封装</a> <a href="/tags/开发环境/" style="font-size: 10px;">开发环境</a> <a href="/tags/心情/" style="font-size: 10px;">心情</a> <a href="/tags/心灵驿站/" style="font-size: 10px;">心灵驿站</a> <a href="/tags/情感/" style="font-size: 10px;">情感</a> <a href="/tags/搜狐畅言/" style="font-size: 10px;">搜狐畅言</a> <a href="/tags/数据结构/" style="font-size: 10px;">数据结构</a> <a href="/tags/日常修仙/" style="font-size: 10px;">日常修仙</a> <a href="/tags/服务器数据Mock/" style="font-size: 10px;">服务器数据Mock</a> <a href="/tags/杂货/" style="font-size: 10px;">杂货</a> <a href="/tags/柯里化/" style="font-size: 10px;">柯里化</a> <a href="/tags/气泡提示/" style="font-size: 10px;">气泡提示</a> <a href="/tags/生产环境/" style="font-size: 10px;">生产环境</a> <a href="/tags/简单工厂模式/" style="font-size: 10px;">简单工厂模式</a> <a href="/tags/腾讯云/" style="font-size: 10px;">腾讯云</a> <a href="/tags/设计模式/" style="font-size: 12.5px;">设计模式</a> <a href="/tags/调试/" style="font-size: 10px;">调试</a> <a href="/tags/跨域/" style="font-size: 10px;">跨域</a>
        </div>
    </div>
</div>
<div class="search-wrap">
    <span class="search-close">&times;</span>
        <a href="javascript:;" class="header-icon waves-effect waves-circle waves-light" id="back">
            <i class="icon icon-lg icon-chevron-left"></i>
        </a>
        <input class="search-field" placeholder="Search..." id="keywords">
        <a id="search-submit" href="javascript:;">
            <i class="fa fa-search"></i>
        </a>
    <div class="search-container" id="search-container">
        <ul class="search-result" id="search-result">
        </ul>
    </div>
</div>

<div id="search-tpl">
    <li class="search-result-item">
        <a href="{url}" class="search-item-li">
            <span class="search-item-li-title" title="{title}">{title}</span>
        </a>
    </li>
</div>
<script src="/js/search.js"></script>
<script src="/js/main.js"></script>


  <script src="//cdn.bootcss.com/particles.js/2.0.0/particles.min.js"></script>
  <div id="particles"></div>
  <script src="/js/particles.js"></script>







  <link rel="stylesheet" href="//cdn.bootcss.com/animate.css/3.5.0/animate.min.css">
  <script src="//cdn.bootcss.com/scrollReveal.js/3.0.5/scrollreveal.js"></script>
  <script src="/js/animate.js"></script>


  <script src="/js/pop-img.js"></script>
  <script>
     $(".article-entry p img").popImg();
  </script>

  </div>
</body>
</html>